<?php

namespace app\controller\admin;


use app\bll\Organ as BllOrgan;
use app\bll\Site as BllSite;
use core\controller\AdminBase;
use support\View;

class Organ extends AdminBase
{
    public function index()
    {
        $bllSite = new BllSite();
        $siteinfo = $bllSite->find(request()->nowsiteid);
        if (!$siteinfo['orgid'] || $siteinfo['orgid'] == 0) {
        } else {
            $bllOrgan = new BllOrgan();
            $orgs = $bllOrgan->cascaderBySiteid(request()->nowsiteid);
            //本站点所属的组织 下的部门和单位
            View::assign('orgs', $orgs);
        }
        View::assign('siteinfo', $siteinfo);
        return $this->view();
    }

    


}
